package com.gm.commonlib.util.permission.interfaces;

import android.app.Activity;
import android.content.Context;

import com.gm.commonlib.util.permission.utils.Utils;

import java.util.Set;

public abstract class IPermissionCallback {

    public boolean preCheckPermission(Context context, String[] permissions) {
        if (context instanceof Activity) {
            return Utils.isAllPermissionsPass((Activity) context, permissions);
        }
        return false;
    }

    public void statisticsPermission(Set<String> deniedSet, Set<String> passSet) {

    }

    public abstract void onPermissionResult(boolean result, Set<String> dataSet);
}
